package com.hsteach.dao.mapper.buildingApply;

import com.hsteach.dao.domain.buildingApply.BuildingApply;
import org.apache.ibatis.annotations.Param;

import java.util.Date;
import java.util.List;

/**
 * 场所申请Mapper接口
 * 
 * @author fanxquer
 * @date 2023-08-25
 */
public interface BuildingApplyMapper 
{
    /**
     * 查询场所申请
     * 
     * @param id 场所申请主键
     * @return 场所申请
     */
    public BuildingApply selectBuildingApplyById(Long id);

    /**
     * 查询场所申请列表
     * 
     * @param buildingApply 场所申请
     * @return 场所申请集合
     */
    public List<BuildingApply> selectBuildingApplyList(BuildingApply buildingApply);

    public List<BuildingApply> selectBuildingApplyReviewList(BuildingApply buildingApply);

    public List<BuildingApply> selectByDateAndBuildId(@Param("orgCode") String orgCode, @Param("dates") List<Date> dates, @Param("buildIds") List<String> buildIds);

    public List<BuildingApply> listBuildingApply(BuildingApply buildingApply);

    /**
     * 新增场所申请
     * 
     * @param buildingApply 场所申请
     * @return 结果
     */
    public int insertBuildingApply(BuildingApply buildingApply);

    public int batchInsert(List<BuildingApply> list);

    /**
     * 修改场所申请
     * 
     * @param buildingApply 场所申请
     * @return 结果
     */
    public int updateBuildingApply(BuildingApply buildingApply);

    public int updateByRepeatId(BuildingApply buildingApply);

    /**
     * 删除场所申请
     * 
     * @param id 场所申请主键
     * @return 结果
     */
    public int deleteBuildingApplyById(Long id);

    /**
     * 批量删除场所申请
     * 
     * @param ids 需要删除的数据主键集合
     * @return 结果
     */
    public int deleteBuildingApplyByIds(Long[] ids);
    public int batchCancel(List<Long> ids);

    public Long selectCount(BuildingApply buildingApply);
}
